Skip to content

Conversation

@jledet
Copy link
Contributor

@jledet jledet commented Jul 7, 2025

Erasing the line and rewriting everything on every change is simple, but works poorly with slow serial speeds and can still create visible refresh artifacts with faster speeds.

Rewrite the refresh routine to keep track of the screen cursor and line length and try to refresh fewer bytes. We still need a boolean to force a full reset after we print completion lists. A full buffer reset is also used when browsing the history, which could probably be optimized further.

Erasing the line and rewriting everything on every change is simple, but
works poorly with slow serial speeds and can still create visible
refresh artifacts with faster speeds.

Rewrite the refresh routine to keep track of the screen cursor and line
length and try to refresh fewer bytes. We still need a boolean to force
a full reset after we print completion lists. A full buffer reset is
also used when browsing the history, which could probably be optimized
further.

Signed-off-by: Jeppe Ledet-Pedersen <jlp@satlab.com>
@jledet jledet merged commit dd306bc into main Jul 7, 2025
1 check passed
@jledet jledet deleted the feature_optimize-refresh branch July 7, 2025 17:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants